//
//  NightManager.m
//  夜间模式
//
//  Created by dllo on 15/4/21.
//  Copyright (c) 2015年 dllo. All rights reserved.
//

#import "NightManager.h"
#define BLACK [UIColor blackColor]
#define WHITE [UIColor whiteColor]
#import "NightMode.h"

@implementation NightManager

+ (void)setLabelColorWithLabel:(UILabel *)label {
    
    if ([NightMode shareNightMode].isNight) {
        label.textColor = WHITE;
    } else {
        label.textColor = BLACK;
    }
    
}

+ (void)setBackgroundColorWithView:(UIView *)view {
    if ([NightMode shareNightMode].isNight) {
        view.backgroundColor = BLACK;
    } else {
        view.backgroundColor = WHITE;
    }
}

+ (void)setButtonTitleColorWithButton:(UIButton *)button {
    if ([NightMode shareNightMode].isNight) {
        [button setTitleColor:WHITE forState:UIControlStateNormal];
    } else {
        [button setTitleColor:[UIColor blueColor] forState:UIControlStateNormal];
    }
}

@end
